package com.geotmt.billingcenter.modules.designmode.rulesfactory.impl;

import com.geotmt.billingcenter.common.vo.params.RuleVo;
import com.geotmt.billingcenter.modules.designmode.rulesfactory.RulesFactory;
import org.springframework.stereotype.Component;

/**
 * @Description 策略类
 * @Author      yanghanwei
 * @Mail        yanghanwei@geotmt.com
 * @Date        2019/3/25 13:29
 * @Version     v1
 **/
@Component
public class RulesContext {

    private RulesFactory rulesFactory;

    public RulesContext(RulesFactory factory) {
        this.rulesFactory = factory;
    }

    public Double getMoney(RuleVo ruleVo) throws Exception{
        return rulesFactory.getMoney(ruleVo);
    }
}
